execute if data entity @s SelectedItem{components: {"minecraft:custom_data": {id: "faqv:villager_ball", has_villager: 1b}}} if score @s faqv.villager_ball.use_ball matches 1.. at @s run function faqv:villager_ball/use